import axios from 'axios'

let request = axios.create({
  baseURL:'http://localhost:3000/api'
})

function getFile(){
  return request({
    url:'/getFile',
    // responseType:'blob'
  })
}
function setFile(data){
  return request({
    url:'/upload',
    method:'POST',
    data
  })
}
function upBook(data){
  return request({
    url:'/upBook',
    method:'POST',
    data
  })
}
function getData(id){
  return request({
    url:'/getData',
    method:'GET',
    params:id
  })
}
export {getFile,setFile,upBook,getData}